package com.jidolstar.astro
{
	import flash.geom.Point;
	import flash.utils.Dictionary;
	
	/**
	 * 별자리 관리자 
	 */ 
	public class ALConstellationManager
	{
		static private var _singleton:ALConstellationManager;
		
		private var conInfoList:Dictionary;
		private var arrIdentCon:Array;
		private var simpleNameList:Array;
		
		/**
		 * 생성자. 싱글턴 패턴. 직접 생성할 수 없고 ALConstellationManager.instance로 접근한다. 
		 */ 
		public function ALConstellationManager( lock:SingletonLock ) 
		{
			conInfoList = new Dictionary( false );
			conInfoList["and"] = new ALConstellationInfo( "and", 0.5667, 39.25, {"kr":"안드로메다", "en":"Andromeda", "jp":"", "cn":""} );
			conInfoList["ant"] = new ALConstellationInfo( "ant", 10.1167, -33.35, {"kr":"공기펌프", "en":"Antlia", "jp":"", "cn":""} );
			conInfoList["aps"] = new ALConstellationInfo( "aps", 16.1333, -76.5833, {"kr":"극락조", "en":"Apus", "jp":"", "cn":""} );
			conInfoList["aqr"] = new ALConstellationInfo( "aqr", 22.7, -10.4667, {"kr":"물병", "en":"Aquarius", "jp":"", "cn":""} );
			conInfoList["aql"] = new ALConstellationInfo( "aql", 19.6833, 3.3667, {"kr":"독수리", "en":"Aquila", "jp":"", "cn":""} );
			conInfoList["ara"] = new ALConstellationInfo( "ara", 17.2333, -51.1167, {"kr":"제단", "en":"Ara", "jp":"", "cn":""} );
			conInfoList["ari"] = new ALConstellationInfo( "ari", 2.6833, 22.5667, {"kr":"양", "en":"Aries", "jp":"", "cn":""} );
			conInfoList["aur"] = new ALConstellationInfo( "aur", 5.95, 42.8167, {"kr":"마차부", "en":"Auriga", "jp":"", "cn":""} );
			conInfoList["boo"] = new ALConstellationInfo( "boo", 14.6833, 32.3333, {"kr":"목동", "en":"Bootes", "jp":"", "cn":""} );
			conInfoList["cae"] = new ALConstellationInfo( "cae", 4.7167, -38.1667, {"kr":"조각칼", "en":"Caelum", "jp":"", "cn":""} );
			conInfoList["cam"] = new ALConstellationInfo( "cam", 6.15, 71.9667, {"kr":"기린", "en":"Camelopardalis", "jp":"", "cn":""} );
			conInfoList["cnc"] = new ALConstellationInfo( "cnc", 8.5, 23.5667, {"kr":"게", "en":"Cancer", "jp":"", "cn":""} );
			conInfoList["cvn"] = new ALConstellationInfo( "cvn", 13.0167, 42.35, {"kr":"사냥개", "en":"Canes Venatici", "jp":"", "cn":""} );
			conInfoList["cma"] = new ALConstellationInfo( "cma", 6.8333, -22.3167, {"kr":"큰개", "en":"Canis Major", "jp":"", "cn":""} );
			conInfoList["cmi"] = new ALConstellationInfo( "cmi", 7.6167, 6.7667, {"kr":"작은개", "en":"Canis Minor", "jp":"", "cn":""} );
			conInfoList["cap"] = new ALConstellationInfo( "cap", 21.05, -19.35, {"kr":"염소", "en":"Capricornus", "jp":"", "cn":""} );
			conInfoList["car"] = new ALConstellationInfo( "car", 7.7667, -57.8333, {"kr":"용골", "en":"Carina", "jp":"", "cn":""} );
			conInfoList["cas"] = new ALConstellationInfo( "cas", 0.8667, 60.3, {"kr":"카시오페아", "en":"Cassiopeia", "jp":"", "cn":""} );
			conInfoList["cen"] = new ALConstellationInfo( "cen", 12.95, -44, {"kr":"켄타우루스", "en":"Centaurus", "jp":"", "cn":""} );
			conInfoList["cep"] = new ALConstellationInfo( "cep", 22.4167, 72.5667, {"kr":"케페우스", "en":"Cepheus", "jp":"", "cn":""} );
			conInfoList["cet"] = new ALConstellationInfo( "cet", 1.7167, -6.3667, {"kr":"고래", "en":"Cetus", "jp":"", "cn":""} );
			conInfoList["cha"] = new ALConstellationInfo( "cha", 12, -81.0167, {"kr":"카멜레온", "en":"Chamaeleon", "jp":"", "cn":""} );
			conInfoList["cir"] = new ALConstellationInfo( "cir", 14.5333, -67.3, {"kr":"컴파스", "en":"Circinus", "jp":"", "cn":""} );
			conInfoList["col"] = new ALConstellationInfo( "col", 5.7, -37.9167, {"kr":"비둘기", "en":"Columba", "jp":"", "cn":""} );
			conInfoList["com"] = new ALConstellationInfo( "com", 12.75, 22.65, {"kr":"머리털", "en":"Coma Berenices", "jp":"", "cn":""} );
			conInfoList["cra"] = new ALConstellationInfo( "cra", 18.65, -41.75, {"kr":"남쪽왕관", "en":"Corona Australis", "jp":"", "cn":""} );
			conInfoList["crb"] = new ALConstellationInfo( "crb", 15.8833, 32.6333, {"kr":"북쪽왕관", "en":"Corona Borealis", "jp":"", "cn":""} );
			conInfoList["crv"] = new ALConstellationInfo( "crv", 12.3833, -18.6333, {"kr":"까마귀", "en":"Corvus", "jp":"", "cn":""} );
			conInfoList["crt"] = new ALConstellationInfo( "crt", 11.35, -16, {"kr":"컵", "en":"Crater", "jp":"", "cn":""} );
			conInfoList["cru"] = new ALConstellationInfo( "cru", 12.4833, -60.3, {"kr":"남십자", "en":"Crux", "jp":"", "cn":""} );
			conInfoList["cyg"] = new ALConstellationInfo( "cyg", 20.6, 49.5833, {"kr":"백조", "en":"Cygnus", "jp":"", "cn":""} );
			conInfoList["del"] = new ALConstellationInfo( "del", 20.6667, 12.1, {"kr":"돌고래", "en":"Delphinus", "jp":"", "cn":""} );
			conInfoList["dor"] = new ALConstellationInfo( "dor", 5.3333, -63.0167, {"kr":"황새치", "en":"Dorado", "jp":"", "cn":""} );
			conInfoList["dra"] = new ALConstellationInfo( "dra", 17.95, 66.0667, {"kr":"용", "en":"Draco", "jp":"", "cn":""} );
			conInfoList["equ"] = new ALConstellationInfo( "equ", 21.25, 7.9333, {"kr":"조랑말", "en":"Equuleus", "jp":"", "cn":""} );
			conInfoList["eri"] = new ALConstellationInfo( "eri", 3.8833, -17.9833, {"kr":"에리다누스", "en":"Eridanus", "jp":"", "cn":""} );
			conInfoList["for"] = new ALConstellationInfo( "for", 2.7667, -26.0667, {"kr":"화로", "en":"Fornax", "jp":"", "cn":""} );
			conInfoList["gem"] = new ALConstellationInfo( "gem", 6.85, 24.8167, {"kr":"쌍둥이", "en":"Gemini", "jp":"", "cn":""} );
			conInfoList["gru"] = new ALConstellationInfo( "gru", 22.45, -45.8167, {"kr":"두루미", "en":"Grus", "jp":"", "cn":""} );
			conInfoList["her"] = new ALConstellationInfo( "her", 17.4333, 31.2333, {"kr":"헤라클레스", "en":"Hercules", "jp":"", "cn":""} );
			conInfoList["hor"] = new ALConstellationInfo( "hor", 3.2167, -52, {"kr":"시계", "en":"Horologium", "jp":"", "cn":""} );
			conInfoList["hya"] = new ALConstellationInfo( "hya", 9.1333, -11.6833, {"kr":"바다뱀", "en":"Hydra", "jp":"", "cn":""} );
			conInfoList["hyi"] = new ALConstellationInfo( "hyi", 2.5833, -72.9167, {"kr":"물뱀", "en":"Hydrus", "jp":"", "cn":""} );
			conInfoList["ind"] = new ALConstellationInfo( "ind", 21.1333, -52.3167, {"kr":"인디언", "en":"Indus", "jp":"", "cn":""} );
			conInfoList["lac"] = new ALConstellationInfo( "lac", 22.5167, 46.6667, {"kr":"도마뱀", "en":"Lacerta", "jp":"", "cn":""} );
			conInfoList["leo"] = new ALConstellationInfo( "leo", 10, 7, {"kr":"사자", "en":"Leo", "jp":"", "cn":""} );
			conInfoList["lmi"] = new ALConstellationInfo( "lmi", 10.3167, 33.2333, {"kr":"작은사자", "en":"Leo Minor", "jp":"", "cn":""} );
			conInfoList["lep"] = new ALConstellationInfo( "lep", 5.4333, -19.65, {"kr":"토끼", "en":"Lepus", "jp":"", "cn":""} );
			conInfoList["lib"] = new ALConstellationInfo( "lib", 15.1833, -15.55, {"kr":"천칭", "en":"Libra", "jp":"", "cn":""} );
			conInfoList["lup"] = new ALConstellationInfo( "lup", 15.3833, -42.7167, {"kr":"이리", "en":"Lupus", "jp":"", "cn":""} );
			conInfoList["lyn"] = new ALConstellationInfo( "lyn", 7.7333, 47.8333, {"kr":"살쾡이", "en":"Lynx", "jp":"", "cn":""} );
			conInfoList["lyr"] = new ALConstellationInfo( "lyr", 18.9, 40.65, {"kr":"거문고", "en":"Lyra", "jp":"", "cn":""} );
			conInfoList["men"] = new ALConstellationInfo( "men", 5.5, -79.0167, {"kr":"테이블", "en":"Mensa", "jp":"", "cn":""} );
			conInfoList["mic"] = new ALConstellationInfo( "mic", 20.95, -37.8, {"kr":"현미경", "en":"Microscopium", "jp":"", "cn":""} );
			conInfoList["mon"] = new ALConstellationInfo( "mon", 6.9667, -3.2667, {"kr":"외뿔소", "en":"Monoceros", "jp":"", "cn":""} );
			conInfoList["mus"] = new ALConstellationInfo( "mus", 12.4667, -69.1333, {"kr":"파리", "en":"Musca", "jp":"", "cn":""} );
			conInfoList["nor"] = new ALConstellationInfo( "nor", 16.05, -52.7167, {"kr":"직각자", "en":"Norma", "jp":"", "cn":""} );
			conInfoList["oct"] = new ALConstellationInfo( "oct", 22.1667, -84.2667, {"kr":"팔분의", "en":"Octans", "jp":"", "cn":""} );
			conInfoList["oph"] = new ALConstellationInfo( "oph", 17.0333, -2.35, {"kr":"뱀주인", "en":"Ophiuchus", "jp":"", "cn":""} );
			conInfoList["ori"] = new ALConstellationInfo( "ori", 5.5667, 3.5833, {"kr":"오리온", "en":"Orion", "jp":"", "cn":""} );
			conInfoList["pav"] = new ALConstellationInfo( "pav", 19.1667, -65.8667, {"kr":"공작", "en":"Pavo", "jp":"", "cn":""} );
			conInfoList["peg"] = new ALConstellationInfo( "peg", 22.6167, 19.65, {"kr":"페가수스", "en":"Pegasus", "jp":"", "cn":""} );
			conInfoList["per"] = new ALConstellationInfo( "per", 3.5167, 44.7667, {"kr":"페르세우스", "en":"Perseus", "jp":"", "cn":""} );
			conInfoList["phe"] = new ALConstellationInfo( "phe", 0.7333, -48.7667, {"kr":"봉황", "en":"Phoenix", "jp":"", "cn":""} );
			conInfoList["pic"] = new ALConstellationInfo( "pic", 5.3833, -51.3667, {"kr":"화가", "en":"Pictor", "jp":"", "cn":""} );
			conInfoList["psc"] = new ALConstellationInfo( "psc", 0.8833, 15.4833, {"kr":"물고기", "en":"Pisces", "jp":"", "cn":""} );
			conInfoList["psa"] = new ALConstellationInfo( "psa", 22.4167, -31.5667, {"kr":"남쪽물고기", "en":"Piscis Austrinus", "jp":"", "cn":""} );
			conInfoList["pup"] = new ALConstellationInfo( "pup", 7.8667, -32.6167, {"kr":"고물", "en":"Puppis", "jp":"", "cn":""} );
			conInfoList["pyx"] = new ALConstellationInfo( "pyx", 8.8833, -29.7833, {"kr":"나침반", "en":"Pyxis", "jp":"", "cn":""} );
			conInfoList["ret"] = new ALConstellationInfo( "ret", 3.9, -60.5167, {"kr":"그물", "en":"Reticulum", "jp":"", "cn":""} );
			conInfoList["sge"] = new ALConstellationInfo( "sge", 19.6667, 17, {"kr":"화살", "en":"Sagitta", "jp":"", "cn":""} );
			conInfoList["sgr"] = new ALConstellationInfo( "sgr", 19.3833, -29.8833, {"kr":"궁수", "en":"Sagittarius", "jp":"", "cn":""} );
			conInfoList["sco"] = new ALConstellationInfo( "sco", 16.8667, -35.3333, {"kr":"전갈", "en":"Scorpius", "jp":"", "cn":""} );
			conInfoList["scl"] = new ALConstellationInfo( "scl", 1, -38.5167, {"kr":"조각가", "en":"Sculptor", "jp":"", "cn":""} );
			conInfoList["sct"] = new ALConstellationInfo( "sct", 18.65, -10.8833, {"kr":"방패", "en":"Scutum", "jp":"", "cn":""} );
			conInfoList["ser"] = new ALConstellationInfo( "ser", 15.7333, 10.85, {"kr":"뱀", "en":"Serpens", "jp":"", "cn":""} );
			conInfoList["sex"] = new ALConstellationInfo( "sex", 10.1, -1.1333, {"kr":"육분의", "en":"Sextans", "jp":"", "cn":""} );
			conInfoList["tau"] = new ALConstellationInfo( "tau", 4.1, 17.3333, {"kr":"황소", "en":"Taurus", "jp":"", "cn":""} );
			conInfoList["tel"] = new ALConstellationInfo( "tel", 19.25, -51.4667, {"kr":"망원경", "en":"Telescopium", "jp":"", "cn":""} );
			conInfoList["tri"] = new ALConstellationInfo( "tri", 2.05, 32.3333, {"kr":"삼각형", "en":"Triangulum", "jp":"", "cn":""} );
			conInfoList["tra"] = new ALConstellationInfo( "tra", 16.1167, -65.1, {"kr":"남쪽삼각형", "en":"Triangulum Australe", "jp":"", "cn":""} );
			conInfoList["tuc"] = new ALConstellationInfo( "tuc", 23.8333, -64.9333, {"kr":"큰부리새", "en":"Tucana", "jp":"", "cn":""} );
			conInfoList["uma"] = new ALConstellationInfo( "uma", 10.2667, 57.4833, {"kr":"큰곰", "en":"Ursa Major", "jp":"", "cn":""} );
			conInfoList["umi"] = new ALConstellationInfo( "umi", 14.9667, 75.0333, {"kr":"작은곰", "en":"Ursa Minor", "jp":"", "cn":""} );
			conInfoList["vel"] = new ALConstellationInfo( "vel", 9.3333, -48.4833, {"kr":"돛", "en":"Vela", "jp":"", "cn":""} );
			conInfoList["vir"] = new ALConstellationInfo( "vir", 13.35, -3.5167, {"kr":"처녀", "en":"Virgo", "jp":"", "cn":""} );
			conInfoList["vol"] = new ALConstellationInfo( "vol", 7.6667, -69.6167, {"kr":"날치", "en":"Volans", "jp":"", "cn":""} );
			conInfoList["vul"] = new ALConstellationInfo( "vul", 20.3667, 25.0333, {"kr":"작은여우", "en":"Vulpecula", "jp":"", "cn":""} );					
		}
		
		/**
		 * 싱글턴 패턴을 위한 접근자.
		 */ 
		static public function get instance():ALConstellationManager
		{
			if( _singleton == null )
			{
				_singleton = new ALConstellationManager( new SingletonLock() );
			}
			return _singleton;
		}
		
		
		/**
		 * 별자리 약명으로 별자리 정보 반환
		 * @param simpleName 별자리 약명
		 * @return 별자리 정보 
		 */ 
		public function getInfoFromSimpleName( simpleName:String ):ALConstellationInfo
		{
			if( simpleName == null ) return null;
			return conInfoList[simpleName.toLowerCase()];
		}

		/**
		 * 별자리 약명으로 별자리 index 반환 
		 * @param simpleName 별자리 약명
		 * @return 별자리 Index, 약명순 Index이다. 
		 */ 		
		public function getIndexFromSimpleName( simpleName:String ):int
		{
			if( simpleName == null ) return -1;
			simpleName = simpleName.toLowerCase();
			var i:int = 0
			var list:Array = getSimpleNameList();
			var length:int = list.length;
			for( i = 0; i < length; i++ )
			{
				if( list[i] == simpleName ) return i;
			}
			return -1;
		}
		
		/**
		 * 별자리 이름 
		 * @param simpleName 별자리 약명 
		 * @param language 언어
		 */ 
		public function getName( simpleName:String, language:String = "kr" ):String
		{
			var info:ALConstellationInfo = getInfoFromSimpleName( simpleName );
			if( info )
			{
				return info.getName( language );	
			}
			return null;
		}
		
		/**
		 * 별자리 약명 리스트 반환 
		 * @return 별자리 약명 리스트 
		 */ 
		public function getSimpleNameList():Array
		{
			if( simpleNameList == null )
			{
				simpleNameList = [];
				for( var name:String in conInfoList )
				{
					simpleNameList.push( name );	
				}
			}
			simpleNameList = simpleNameList.sort();
			return simpleNameList;
		}
		
		/**
		 * 별자리 수 
		 * @return 별자리 수 
		 */ 
		public function get numOfContellations():int
		{
			return 88;
		}
		
		private var prevEpoch:Number;
		private var precessionEquMatrix:ALMatrix3D;
		
		/**
		 * 주어진 원기에서 적경과 적위에 대한 별자리 찾아내기
		 * @param raHour 적경(단위 Hour)
		 * @param dec 적위(단위 degree)
		 * @param 원기. 기본 1875년.
		 */ 
		public function identifyConstellation( raHour:Number, dec:Number, epoch:Number=1875 ):ALConstellationInfo
		{
			if( arrIdentCon == null )
			{
				createIdentification();
			}
			
			// 인자로 넘어온 적경적위가 1875년 원기가 이닐때 
			// 1875년 원기로 하는  적경,적위를 구한뒤 어느 별자리에 속한지  계산해야한다.
			if( epoch != 1875 )
			{
				
				var equCoord:Point;
				equCoord = applyHergetPrecession( raHour, dec, epoch, 1875 );
				raHour = equCoord.x;
				dec = equCoord.y;
				/*
				if( epoch != prevEpoch || precessionEquMatrix == null)
				{
					var fromJDE:Number = ALDate.date2JD( epoch, 1, 1, 0, 0, 0 );
					var toJDE:Number = ALDate.date2JD( 1875, 1, 1, 0, 0, 0 );
					var precession:ALPrecession = new ALPrecession( fromJDE, toJDE, ALPrecession.BASED_SYSTEM_IAU1976 );
					precessionEquMatrix = precession.getPrecessionOfEquMatrix();
					prevEpoch = epoch;
					trace( "new" );  
				}
				var equVec:ALVector3D = new ALVector3D( raHour * ALConst.H2R, dec * ALConst.D2R, 1, ALVector3D.COORDINATE_TYPE_SPHERICAL );
				var equCoord:ALVector3D = precessionEquMatrix.multiply3x3ByVector3D( [equVec] )[0];
				raHour = equCoord.longitudeHour;
				dec = equCoord.latitudeDegree;
				*/
			}			
			//trace( "identifyConstellation", raHour, dec );
			
			var i:int;
			var info:Object;
			var rau:Number;
			var ral:Number;
			var decl:Number;
			var conname:String;
			for(i=0; i < arrIdentCon.length; i++)
			{
				info = arrIdentCon[i];
				rau = info.rau;
				ral = info.ral;
				decl = info.dec;
				if( decl > dec ) continue;
				if( rau <= raHour ) continue;
				if( ral > raHour ) continue;
				
				if( raHour >= ral && raHour < rau && decl <= dec )
					return getInfoFromSimpleName( info.conname );
				else if(rau < raHour)
					continue;
				else
					return null;
			}
			return null;
		}
		
		private function createIdentification():void
		{
			//임의의 적경(h), 적위(deg) 로 부터 해당 별자리 반환하기 위해 사용 
			//Identification of a Constellation From Position  (Roman 1987)
			//http://cdsarc.u-strasbg.fr/viz-bin/Cat?VI/42	
			arrIdentCon = new Array();
			arrIdentCon.push({ral: 0.0000, rau:24.0000, dec: 88.0000, conname:"UMI"});
			arrIdentCon.push({ral: 8.0000, rau:14.5000, dec: 86.5000, conname:"UMI"});
			arrIdentCon.push({ral:21.0000, rau:23.0000, dec: 86.1667, conname:"UMI"});
			arrIdentCon.push({ral:18.0000, rau:21.0000, dec: 86.0000, conname:"UMI"});
			arrIdentCon.push({ral: 0.0000, rau: 8.0000, dec: 85.0000, conname:"CEP"});
			arrIdentCon.push({ral: 9.1667, rau:10.6667, dec: 82.0000, conname:"CAM"});
			arrIdentCon.push({ral: 0.0000, rau: 5.0000, dec: 80.0000, conname:"CEP"});
			arrIdentCon.push({ral:10.6667, rau:14.5000, dec: 80.0000, conname:"CAM"});
			arrIdentCon.push({ral:17.5000, rau:18.0000, dec: 80.0000, conname:"UMI"});
			arrIdentCon.push({ral:20.1667, rau:21.0000, dec: 80.0000, conname:"DRA"});
			arrIdentCon.push({ral: 0.0000, rau: 3.5083, dec: 77.0000, conname:"CEP"});
			arrIdentCon.push({ral:11.5000, rau:13.5833, dec: 77.0000, conname:"CAM"});
			arrIdentCon.push({ral:16.5333, rau:17.5000, dec: 75.0000, conname:"UMI"});
			arrIdentCon.push({ral:20.1667, rau:20.6667, dec: 75.0000, conname:"CEP"});
			arrIdentCon.push({ral: 7.9667, rau: 9.1667, dec: 73.5000, conname:"CAM"});
			arrIdentCon.push({ral: 9.1667, rau:11.3333, dec: 73.5000, conname:"DRA"});
			arrIdentCon.push({ral:13.0000, rau:16.5333, dec: 70.0000, conname:"UMI"});
			arrIdentCon.push({ral: 3.1000, rau: 3.4167, dec: 68.0000, conname:"CAS"});
			arrIdentCon.push({ral:20.4167, rau:20.6667, dec: 67.0000, conname:"DRA"});
			arrIdentCon.push({ral:11.3333, rau:12.0000, dec: 66.5000, conname:"DRA"});
			arrIdentCon.push({ral: 0.0000, rau: 0.3333, dec: 66.0000, conname:"CEP"});
			arrIdentCon.push({ral:14.0000, rau:15.6667, dec: 66.0000, conname:"UMI"});
			arrIdentCon.push({ral:23.5833, rau:24.0000, dec: 66.0000, conname:"CEP"});
			arrIdentCon.push({ral:12.0000, rau:13.5000, dec: 64.0000, conname:"DRA"});
			arrIdentCon.push({ral:13.5000, rau:14.4167, dec: 63.0000, conname:"DRA"});
			arrIdentCon.push({ral:23.1667, rau:23.5833, dec: 63.0000, conname:"CEP"});
			arrIdentCon.push({ral: 6.1000, rau: 7.0000, dec: 62.0000, conname:"CAM"});
			arrIdentCon.push({ral:20.0000, rau:20.4167, dec: 61.5000, conname:"DRA"});
			arrIdentCon.push({ral:20.5367, rau:20.6000, dec: 60.9167, conname:"CEP"});
			arrIdentCon.push({ral: 7.0000, rau: 7.9667, dec: 60.0000, conname:"CAM"});
			arrIdentCon.push({ral: 7.9667, rau: 8.4167, dec: 60.0000, conname:"UMA"});
			arrIdentCon.push({ral:19.7667, rau:20.0000, dec: 59.5000, conname:"DRA"});
			arrIdentCon.push({ral:20.0000, rau:20.5367, dec: 59.5000, conname:"CEP"});
			arrIdentCon.push({ral:22.8667, rau:23.1667, dec: 59.0833, conname:"CEP"});
			arrIdentCon.push({ral: 0.0000, rau: 2.4333, dec: 58.5000, conname:"CAS"});
			arrIdentCon.push({ral:19.4167, rau:19.7667, dec: 58.0000, conname:"DRA"});
			arrIdentCon.push({ral: 1.7000, rau: 1.9083, dec: 57.5000, conname:"CAS"});
			arrIdentCon.push({ral: 2.4333, rau: 3.1000, dec: 57.0000, conname:"CAS"});
			arrIdentCon.push({ral: 3.1000, rau: 3.1667, dec: 57.0000, conname:"CAM"});
			arrIdentCon.push({ral:22.3167, rau:22.8667, dec: 56.2500, conname:"CEP"});
			arrIdentCon.push({ral: 5.0000, rau: 6.1000, dec: 56.0000, conname:"CAM"});
			arrIdentCon.push({ral:14.0333, rau:14.4167, dec: 55.5000, conname:"UMA"});
			arrIdentCon.push({ral:14.4167, rau:19.4167, dec: 55.5000, conname:"DRA"});
			arrIdentCon.push({ral: 3.1667, rau: 3.3333, dec: 55.0000, conname:"CAM"});
			arrIdentCon.push({ral:22.1333, rau:22.3167, dec: 55.0000, conname:"CEP"});
			arrIdentCon.push({ral:20.6000, rau:21.9667, dec: 54.8333, conname:"CEP"});
			arrIdentCon.push({ral: 0.0000, rau: 1.7000, dec: 54.0000, conname:"CAS"});
			arrIdentCon.push({ral: 6.1000, rau: 6.5000, dec: 54.0000, conname:"LYN"});
			arrIdentCon.push({ral:12.0833, rau:13.5000, dec: 53.0000, conname:"UMA"});
			arrIdentCon.push({ral:15.2500, rau:15.7500, dec: 53.0000, conname:"DRA"});
			arrIdentCon.push({ral:21.9667, rau:22.1333, dec: 52.7500, conname:"CEP"});
			arrIdentCon.push({ral: 3.3333, rau: 5.0000, dec: 52.5000, conname:"CAM"});
			arrIdentCon.push({ral:22.8667, rau:23.3333, dec: 52.5000, conname:"CAS"});
			arrIdentCon.push({ral:15.7500, rau:17.0000, dec: 51.5000, conname:"DRA"});
			arrIdentCon.push({ral: 2.0417, rau: 2.5167, dec: 50.5000, conname:"PER"});
			arrIdentCon.push({ral:17.0000, rau:18.2333, dec: 50.5000, conname:"DRA"});
			arrIdentCon.push({ral: 0.0000, rau: 1.3667, dec: 50.0000, conname:"CAS"});
			arrIdentCon.push({ral: 1.3667, rau: 1.6667, dec: 50.0000, conname:"PER"});
			arrIdentCon.push({ral: 6.5000, rau: 6.8000, dec: 50.0000, conname:"LYN"});
			arrIdentCon.push({ral:23.3333, rau:24.0000, dec: 50.0000, conname:"CAS"});
			arrIdentCon.push({ral:13.5000, rau:14.0333, dec: 48.5000, conname:"UMA"});
			arrIdentCon.push({ral: 0.0000, rau: 1.1167, dec: 48.0000, conname:"CAS"});
			arrIdentCon.push({ral:23.5833, rau:24.0000, dec: 48.0000, conname:"CAS"});
			arrIdentCon.push({ral:18.1750, rau:18.2333, dec: 47.5000, conname:"HER"});
			arrIdentCon.push({ral:18.2333, rau:19.0833, dec: 47.5000, conname:"DRA"});
			arrIdentCon.push({ral:19.0833, rau:19.1667, dec: 47.5000, conname:"CYG"});
			arrIdentCon.push({ral: 1.6667, rau: 2.0417, dec: 47.0000, conname:"PER"});
			arrIdentCon.push({ral: 8.4167, rau: 9.1667, dec: 47.0000, conname:"UMA"});
			arrIdentCon.push({ral: 0.1667, rau: 0.8667, dec: 46.0000, conname:"CAS"});
			arrIdentCon.push({ral:12.0000, rau:12.0833, dec: 45.0000, conname:"UMA"});
			arrIdentCon.push({ral: 6.8000, rau: 7.3667, dec: 44.5000, conname:"LYN"});
			arrIdentCon.push({ral:21.9083, rau:21.9667, dec: 44.0000, conname:"CYG"});
			arrIdentCon.push({ral:21.8750, rau:21.9083, dec: 43.7500, conname:"CYG"});
			arrIdentCon.push({ral:19.1667, rau:19.4000, dec: 43.5000, conname:"CYG"});
			arrIdentCon.push({ral: 9.1667, rau:10.1667, dec: 42.0000, conname:"UMA"});
			arrIdentCon.push({ral:10.1667, rau:10.7833, dec: 40.0000, conname:"UMA"});
			arrIdentCon.push({ral:15.4333, rau:15.7500, dec: 40.0000, conname:"BOO"});
			arrIdentCon.push({ral:15.7500, rau:16.3333, dec: 40.0000, conname:"HER"});
			arrIdentCon.push({ral: 9.2500, rau: 9.5833, dec: 39.7500, conname:"LYN"});
			arrIdentCon.push({ral: 0.0000, rau: 2.5167, dec: 36.7500, conname:"AND"});
			arrIdentCon.push({ral: 2.5167, rau: 2.5667, dec: 36.7500, conname:"PER"});
			arrIdentCon.push({ral:19.3583, rau:19.4000, dec: 36.5000, conname:"LYR"});
			arrIdentCon.push({ral: 4.5000, rau: 4.6917, dec: 36.0000, conname:"PER"});
			arrIdentCon.push({ral:21.7333, rau:21.8750, dec: 36.0000, conname:"CYG"});
			arrIdentCon.push({ral:21.8750, rau:22.0000, dec: 36.0000, conname:"LAC"});
			arrIdentCon.push({ral: 6.5333, rau: 7.3667, dec: 35.5000, conname:"AUR"});
			arrIdentCon.push({ral: 7.3667, rau: 7.7500, dec: 35.5000, conname:"LYN"});
			arrIdentCon.push({ral: 0.0000, rau: 2.0000, dec: 35.0000, conname:"AND"});
			arrIdentCon.push({ral:22.0000, rau:22.8167, dec: 35.0000, conname:"LAC"});
			arrIdentCon.push({ral:22.8167, rau:22.8667, dec: 34.5000, conname:"LAC"});
			arrIdentCon.push({ral:22.8667, rau:23.5000, dec: 34.5000, conname:"AND"});
			arrIdentCon.push({ral: 2.5667, rau: 2.7167, dec: 34.0000, conname:"PER"});
			arrIdentCon.push({ral:10.7833, rau:11.0000, dec: 34.0000, conname:"UMA"});
			arrIdentCon.push({ral:12.0000, rau:12.3333, dec: 34.0000, conname:"CVN"});
			arrIdentCon.push({ral: 7.7500, rau: 9.2500, dec: 33.5000, conname:"LYN"});
			arrIdentCon.push({ral: 9.2500, rau: 9.8833, dec: 33.5000, conname:"LMI"});
			arrIdentCon.push({ral: 0.7167, rau: 1.4083, dec: 33.0000, conname:"AND"});
			arrIdentCon.push({ral:15.1833, rau:15.4333, dec: 33.0000, conname:"BOO"});
			arrIdentCon.push({ral:23.5000, rau:23.7500, dec: 32.0833, conname:"AND"});
			arrIdentCon.push({ral:12.3333, rau:13.2500, dec: 32.0000, conname:"CVN"});
			arrIdentCon.push({ral:23.7500, rau:24.0000, dec: 31.3333, conname:"AND"});
			arrIdentCon.push({ral:13.9583, rau:14.0333, dec: 30.7500, conname:"CVN"});
			arrIdentCon.push({ral: 2.4167, rau: 2.7167, dec: 30.6667, conname:"TRI"});
			arrIdentCon.push({ral: 2.7167, rau: 4.5000, dec: 30.6667, conname:"PER"});
			arrIdentCon.push({ral: 4.5000, rau: 4.7500, dec: 30.0000, conname:"AUR"});
			arrIdentCon.push({ral:18.1750, rau:19.3583, dec: 30.0000, conname:"LYR"});
			arrIdentCon.push({ral:11.0000, rau:12.0000, dec: 29.0000, conname:"UMA"});
			arrIdentCon.push({ral:19.6667, rau:20.9167, dec: 29.0000, conname:"CYG"});
			arrIdentCon.push({ral: 4.7500, rau: 5.8833, dec: 28.5000, conname:"AUR"});
			arrIdentCon.push({ral: 9.8833, rau:10.5000, dec: 28.5000, conname:"LMI"});
			arrIdentCon.push({ral:13.2500, rau:13.9583, dec: 28.5000, conname:"CVN"});
			arrIdentCon.push({ral: 0.0000, rau: 0.0667, dec: 28.0000, conname:"AND"});
			arrIdentCon.push({ral: 1.4083, rau: 1.6667, dec: 28.0000, conname:"TRI"});
			arrIdentCon.push({ral: 5.8833, rau: 6.5333, dec: 28.0000, conname:"AUR"});
			arrIdentCon.push({ral: 7.8833, rau: 8.0000, dec: 28.0000, conname:"GEM"});
			arrIdentCon.push({ral:20.9167, rau:21.7333, dec: 28.0000, conname:"CYG"});
			arrIdentCon.push({ral:19.2583, rau:19.6667, dec: 27.5000, conname:"CYG"});
			arrIdentCon.push({ral: 1.9167, rau: 2.4167, dec: 27.2500, conname:"TRI"});
			arrIdentCon.push({ral:16.1667, rau:16.3333, dec: 27.0000, conname:"CRB"});
			arrIdentCon.push({ral:15.0833, rau:15.1833, dec: 26.0000, conname:"BOO"});
			arrIdentCon.push({ral:15.1833, rau:16.1667, dec: 26.0000, conname:"CRB"});
			arrIdentCon.push({ral:18.3667, rau:18.8667, dec: 26.0000, conname:"LYR"});
			arrIdentCon.push({ral:10.7500, rau:11.0000, dec: 25.5000, conname:"LMI"});
			arrIdentCon.push({ral:18.8667, rau:19.2583, dec: 25.5000, conname:"LYR"});
			arrIdentCon.push({ral: 1.6667, rau: 1.9167, dec: 25.0000, conname:"TRI"});
			arrIdentCon.push({ral: 0.7167, rau: 0.8500, dec: 23.7500, conname:"PSC"});
			arrIdentCon.push({ral:10.5000, rau:10.7500, dec: 23.5000, conname:"LMI"});
			arrIdentCon.push({ral:21.2500, rau:21.4167, dec: 23.5000, conname:"VUL"});
			arrIdentCon.push({ral: 5.7000, rau: 5.8833, dec: 22.8333, conname:"TAU"});
			arrIdentCon.push({ral: 0.0667, rau: 0.1417, dec: 22.0000, conname:"AND"});
			arrIdentCon.push({ral:15.9167, rau:16.0333, dec: 22.0000, conname:"SER"});
			arrIdentCon.push({ral: 5.8833, rau: 6.2167, dec: 21.5000, conname:"GEM"});
			arrIdentCon.push({ral:19.8333, rau:20.2500, dec: 21.2500, conname:"VUL"});
			arrIdentCon.push({ral:18.8667, rau:19.2500, dec: 21.0833, conname:"VUL"});
			arrIdentCon.push({ral: 0.1417, rau: 0.8500, dec: 21.0000, conname:"AND"});
			arrIdentCon.push({ral:20.2500, rau:20.5667, dec: 20.5000, conname:"VUL"});
			arrIdentCon.push({ral: 7.8083, rau: 7.8833, dec: 20.0000, conname:"GEM"});
			arrIdentCon.push({ral:20.5667, rau:21.2500, dec: 19.5000, conname:"VUL"});
			arrIdentCon.push({ral:19.2500, rau:19.8333, dec: 19.1667, conname:"VUL"});
			arrIdentCon.push({ral: 3.2833, rau: 3.3667, dec: 19.0000, conname:"ARI"});
			arrIdentCon.push({ral:18.8667, rau:19.0000, dec: 18.5000, conname:"SGE"});
			arrIdentCon.push({ral: 5.7000, rau: 5.7667, dec: 18.0000, conname:"ORI"});
			arrIdentCon.push({ral: 6.2167, rau: 6.3083, dec: 17.5000, conname:"GEM"});
			arrIdentCon.push({ral:19.0000, rau:19.8333, dec: 16.1667, conname:"SGE"});
			arrIdentCon.push({ral: 4.9667, rau: 5.3333, dec: 16.0000, conname:"TAU"});
			arrIdentCon.push({ral:15.9167, rau:16.0833, dec: 16.0000, conname:"HER"});
			arrIdentCon.push({ral:19.8333, rau:20.2500, dec: 15.7500, conname:"SGE"});
			arrIdentCon.push({ral: 4.6167, rau: 4.9667, dec: 15.5000, conname:"TAU"});
			arrIdentCon.push({ral: 5.3333, rau: 5.6000, dec: 15.5000, conname:"TAU"});
			arrIdentCon.push({ral:12.8333, rau:13.5000, dec: 15.0000, conname:"COM"});
			arrIdentCon.push({ral:17.2500, rau:18.2500, dec: 14.3333, conname:"HER"});
			arrIdentCon.push({ral:11.8667, rau:12.8333, dec: 14.0000, conname:"COM"});
			arrIdentCon.push({ral: 7.5000, rau: 7.8083, dec: 13.5000, conname:"GEM"});
			arrIdentCon.push({ral:16.7500, rau:17.2500, dec: 12.8333, conname:"HER"});
			arrIdentCon.push({ral: 0.0000, rau: 0.1417, dec: 12.5000, conname:"PEG"});
			arrIdentCon.push({ral: 5.6000, rau: 5.7667, dec: 12.5000, conname:"TAU"});
			arrIdentCon.push({ral: 7.0000, rau: 7.5000, dec: 12.5000, conname:"GEM"});
			arrIdentCon.push({ral:21.1167, rau:21.3333, dec: 12.5000, conname:"PEG"});
			arrIdentCon.push({ral: 6.3083, rau: 6.9333, dec: 12.0000, conname:"GEM"});
			arrIdentCon.push({ral:18.2500, rau:18.8667, dec: 12.0000, conname:"HER"});
			arrIdentCon.push({ral:20.8750, rau:21.0500, dec: 11.8333, conname:"DEL"});
			arrIdentCon.push({ral:21.0500, rau:21.1167, dec: 11.8333, conname:"PEG"});
			arrIdentCon.push({ral:11.5167, rau:11.8667, dec: 11.0000, conname:"LEO"});
			arrIdentCon.push({ral: 6.2417, rau: 6.3083, dec: 10.0000, conname:"ORI"});
			arrIdentCon.push({ral: 6.9333, rau: 7.0000, dec: 10.0000, conname:"GEM"});
			arrIdentCon.push({ral: 7.8083, rau: 7.9250, dec: 10.0000, conname:"CNC"});
			arrIdentCon.push({ral:23.8333, rau:24.0000, dec: 10.0000, conname:"PEG"});
			arrIdentCon.push({ral: 1.6667, rau: 3.2833, dec:  9.9167, conname:"ARI"});
			arrIdentCon.push({ral:20.1417, rau:20.3000, dec:  8.5000, conname:"DEL"});
			arrIdentCon.push({ral:13.5000, rau:15.0833, dec:  8.0000, conname:"BOO"});
			arrIdentCon.push({ral:22.7500, rau:23.8333, dec:  7.5000, conname:"PEG"});
			arrIdentCon.push({ral: 7.9250, rau: 9.2500, dec:  7.0000, conname:"CNC"});
			arrIdentCon.push({ral: 9.2500, rau:10.7500, dec:  7.0000, conname:"LEO"});
			arrIdentCon.push({ral:18.2500, rau:18.6622, dec:  6.2500, conname:"OPH"});
			arrIdentCon.push({ral:18.6622, rau:18.8667, dec:  6.2500, conname:"AQL"});
			arrIdentCon.push({ral:20.8333, rau:20.8750, dec:  6.0000, conname:"DEL"});
			arrIdentCon.push({ral: 7.0000, rau: 7.0167, dec:  5.5000, conname:"CMI"});
			arrIdentCon.push({ral:18.2500, rau:18.4250, dec:  4.5000, conname:"SER"});
			arrIdentCon.push({ral:16.0833, rau:16.7500, dec:  4.0000, conname:"HER"});
			arrIdentCon.push({ral:18.2500, rau:18.4250, dec:  3.0000, conname:"OPH"});
			arrIdentCon.push({ral:21.4667, rau:21.6667, dec:  2.7500, conname:"PEG"});
			arrIdentCon.push({ral: 0.0000, rau: 2.0000, dec:  2.0000, conname:"PSC"});
			arrIdentCon.push({ral:18.5833, rau:18.8667, dec:  2.0000, conname:"SER"});
			arrIdentCon.push({ral:20.3000, rau:20.8333, dec:  2.0000, conname:"DEL"});
			arrIdentCon.push({ral:20.8333, rau:21.3333, dec:  2.0000, conname:"EQU"});
			arrIdentCon.push({ral:21.3333, rau:21.4667, dec:  2.0000, conname:"PEG"});
			arrIdentCon.push({ral:22.0000, rau:22.7500, dec:  2.0000, conname:"PEG"});
			arrIdentCon.push({ral:21.6667, rau:22.0000, dec:  1.7500, conname:"PEG"});
			arrIdentCon.push({ral: 7.0167, rau: 7.2000, dec:  1.5000, conname:"CMI"});
			arrIdentCon.push({ral: 3.5833, rau: 4.6167, dec:  0.0000, conname:"TAU"});
			arrIdentCon.push({ral: 4.6167, rau: 4.6667, dec:  0.0000, conname:"ORI"});
			arrIdentCon.push({ral: 7.2000, rau: 8.0833, dec:  0.0000, conname:"CMI"});
			arrIdentCon.push({ral:14.6667, rau:15.0833, dec:  0.0000, conname:"VIR"});
			arrIdentCon.push({ral:17.8333, rau:18.2500, dec:  0.0000, conname:"OPH"});
			arrIdentCon.push({ral: 2.6500, rau: 3.2833, dec:-01.7500, conname:"CET"});
			arrIdentCon.push({ral: 3.2833, rau: 3.5833, dec:-01.7500, conname:"TAU"});
			arrIdentCon.push({ral:15.0833, rau:16.2667, dec:-03.2500, conname:"SER"});
			arrIdentCon.push({ral: 4.6667, rau: 5.0833, dec:-04.0000, conname:"ORI"});
			arrIdentCon.push({ral: 5.8333, rau: 6.2417, dec:-04.0000, conname:"ORI"});
			arrIdentCon.push({ral:17.8333, rau:17.9667, dec:-04.0000, conname:"SER"});
			arrIdentCon.push({ral:18.2500, rau:18.5833, dec:-04.0000, conname:"SER"});
			arrIdentCon.push({ral:18.5833, rau:18.8667, dec:-04.0000, conname:"AQL"});
			arrIdentCon.push({ral:22.7500, rau:23.8333, dec:-04.0000, conname:"PSC"});
			arrIdentCon.push({ral:10.7500, rau:11.5167, dec:-06.0000, conname:"LEO"});
			arrIdentCon.push({ral:11.5167, rau:11.8333, dec:-06.0000, conname:"VIR"});
			arrIdentCon.push({ral: 0.0000, rau:00.3333, dec:-07.0000, conname:"PSC"});
			arrIdentCon.push({ral:23.8333, rau:24.0000, dec:-07.0000, conname:"PSC"});
			arrIdentCon.push({ral:14.2500, rau:14.6667, dec:-08.0000, conname:"VIR"});
			arrIdentCon.push({ral:15.9167, rau:16.2667, dec:-08.0000, conname:"OPH"});
			arrIdentCon.push({ral:20.0000, rau:20.5333, dec:-09.0000, conname:"AQL"});
			arrIdentCon.push({ral:21.3333, rau:21.8667, dec:-09.0000, conname:"AQR"});
			arrIdentCon.push({ral:17.1667, rau:17.9667, dec:-10.0000, conname:"OPH"});
			arrIdentCon.push({ral: 5.8333, rau: 8.0833, dec:-11.0000, conname:"MON"});
			arrIdentCon.push({ral: 4.9167, rau: 5.0833, dec:-11.0000, conname:"ERI"});
			arrIdentCon.push({ral: 5.0833, rau: 5.8333, dec:-11.0000, conname:"ORI"});
			arrIdentCon.push({ral: 8.0833, rau: 8.3667, dec:-11.0000, conname:"HYA"});
			arrIdentCon.push({ral: 9.5833, rau:10.7500, dec:-11.0000, conname:"SEX"});
			arrIdentCon.push({ral:11.8333, rau:12.8333, dec:-11.0000, conname:"VIR"});
			arrIdentCon.push({ral:17.5833, rau:17.6667, dec:-11.6667, conname:"OPH"});
			arrIdentCon.push({ral:18.8667, rau:20.0000, dec:-12.0333, conname:"AQL"});
			arrIdentCon.push({ral: 4.8333, rau: 4.9167, dec:-14.5000, conname:"ERI"});
			arrIdentCon.push({ral:20.5333, rau:21.3333, dec:-15.0000, conname:"AQR"});
			arrIdentCon.push({ral:17.1667, rau:18.2500, dec:-16.0000, conname:"SER"});
			arrIdentCon.push({ral:18.2500, rau:18.8667, dec:-16.0000, conname:"SCT"});
			arrIdentCon.push({ral: 8.3667, rau: 8.5833, dec:-17.0000, conname:"HYA"});
			arrIdentCon.push({ral:16.2667, rau:16.3750, dec:-18.2500, conname:"OPH"});
			arrIdentCon.push({ral: 8.5833, rau: 9.0833, dec:-19.0000, conname:"HYA"});
			arrIdentCon.push({ral:10.7500, rau:10.8333, dec:-19.0000, conname:"CRT"});
			arrIdentCon.push({ral:16.2667, rau:16.3750, dec:-19.2500, conname:"SCO"});
			arrIdentCon.push({ral:15.6667, rau:15.9167, dec:-20.0000, conname:"LIB"});
			arrIdentCon.push({ral:12.5833, rau:12.8333, dec:-22.0000, conname:"CRV"});
			arrIdentCon.push({ral:12.8333, rau:14.2500, dec:-22.0000, conname:"VIR"});
			arrIdentCon.push({ral: 9.0833, rau: 9.7500, dec:-24.0000, conname:"HYA"});
			arrIdentCon.push({ral: 1.6667, rau: 2.6500, dec:-24.3833, conname:"CET"});
			arrIdentCon.push({ral: 2.6500, rau: 3.7500, dec:-24.3833, conname:"ERI"});
			arrIdentCon.push({ral:10.8333, rau:11.8333, dec:-24.5000, conname:"CRT"});
			arrIdentCon.push({ral:11.8333, rau:12.5833, dec:-24.5000, conname:"CRV"});
			arrIdentCon.push({ral:14.2500, rau:14.9167, dec:-24.5000, conname:"LIB"});
			arrIdentCon.push({ral:16.2667, rau:16.7500, dec:-24.5833, conname:"OPH"});
			arrIdentCon.push({ral: 0.0000, rau: 1.6667, dec:-25.5000, conname:"CET"});
			arrIdentCon.push({ral:21.3333, rau:21.8667, dec:-25.5000, conname:"CAP"});
			arrIdentCon.push({ral:21.8667, rau:23.8333, dec:-25.5000, conname:"AQR"});
			arrIdentCon.push({ral:23.8333, rau:24.0000, dec:-25.5000, conname:"CET"});
			arrIdentCon.push({ral: 9.7500, rau:10.2500, dec:-26.5000, conname:"HYA"});
			arrIdentCon.push({ral: 4.7000, rau: 4.8333, dec:-27.2500, conname:"ERI"});
			arrIdentCon.push({ral: 4.8333, rau: 6.1167, dec:-27.2500, conname:"LEP"});
			arrIdentCon.push({ral:20.0000, rau:21.3333, dec:-28.0000, conname:"CAP"});
			arrIdentCon.push({ral:10.2500, rau:10.5833, dec:-29.1667, conname:"HYA"});
			arrIdentCon.push({ral:12.5833, rau:14.9167, dec:-29.5000, conname:"HYA"});
			arrIdentCon.push({ral:14.9167, rau:15.6667, dec:-29.5000, conname:"LIB"});
			arrIdentCon.push({ral:15.6667, rau:16.0000, dec:-29.5000, conname:"SCO"});
			arrIdentCon.push({ral: 4.5833, rau: 4.7000, dec:-30.0000, conname:"ERI"});
			arrIdentCon.push({ral:16.7500, rau:17.6000, dec:-30.0000, conname:"OPH"});
			arrIdentCon.push({ral:17.6000, rau:17.8333, dec:-30.0000, conname:"SGR"});
			arrIdentCon.push({ral:10.5833, rau:10.8333, dec:-31.1667, conname:"HYA"});
			arrIdentCon.push({ral: 6.1167, rau: 7.3667, dec:-33.0000, conname:"CMA"});
			arrIdentCon.push({ral:12.2500, rau:12.5833, dec:-33.0000, conname:"HYA"});
			arrIdentCon.push({ral:10.8333, rau:12.2500, dec:-35.0000, conname:"HYA"});
			arrIdentCon.push({ral: 3.5000, rau: 3.7500, dec:-36.0000, conname:"FOR"});
			arrIdentCon.push({ral: 8.3667, rau: 9.3667, dec:-36.7500, conname:"PYX"});
			arrIdentCon.push({ral: 4.2667, rau: 4.5833, dec:-37.0000, conname:"ERI"});
			arrIdentCon.push({ral:17.8333, rau:19.1667, dec:-37.0000, conname:"SGR"});
			arrIdentCon.push({ral:21.3333, rau:23.0000, dec:-37.0000, conname:"PSA"});
			arrIdentCon.push({ral:23.0000, rau:23.3333, dec:-37.0000, conname:"SCL"});
			arrIdentCon.push({ral: 3.0000, rau: 3.5000, dec:-39.5833, conname:"FOR"});
			arrIdentCon.push({ral: 9.3667, rau:11.0000, dec:-39.7500, conname:"ANT"});
			arrIdentCon.push({ral: 0.0000, rau: 1.6667, dec:-40.0000, conname:"SCL"});
			arrIdentCon.push({ral: 1.6667, rau: 3.0000, dec:-40.0000, conname:"FOR"});
			arrIdentCon.push({ral: 3.8667, rau: 4.2667, dec:-40.0000, conname:"ERI"});
			arrIdentCon.push({ral:23.3333, rau:24.0000, dec:-40.0000, conname:"SCL"});
			arrIdentCon.push({ral:14.1667, rau:14.9167, dec:-42.0000, conname:"CEN"});
			arrIdentCon.push({ral:15.6667, rau:16.0000, dec:-42.0000, conname:"LUP"});
			arrIdentCon.push({ral:16.0000, rau:16.4208, dec:-42.0000, conname:"SCO"});
			arrIdentCon.push({ral: 4.8333, rau: 5.0000, dec:-43.0000, conname:"CAE"});
			arrIdentCon.push({ral: 5.0000, rau: 6.5833, dec:-43.0000, conname:"COL"});
			arrIdentCon.push({ral: 8.0000, rau: 8.3667, dec:-43.0000, conname:"PUP"});
			arrIdentCon.push({ral: 3.4167, rau: 3.8667, dec:-44.0000, conname:"ERI"});
			arrIdentCon.push({ral:16.4208, rau:17.8333, dec:-45.5000, conname:"SCO"});
			arrIdentCon.push({ral:17.8333, rau:19.1667, dec:-45.5000, conname:"CRA"});
			arrIdentCon.push({ral:19.1667, rau:20.3333, dec:-45.5000, conname:"SGR"});
			arrIdentCon.push({ral:20.3333, rau:21.3333, dec:-45.5000, conname:"MIC"});
			arrIdentCon.push({ral: 3.0000, rau: 3.4167, dec:-46.0000, conname:"ERI"});
			arrIdentCon.push({ral: 4.5000, rau: 4.8333, dec:-46.5000, conname:"CAE"});
			arrIdentCon.push({ral:15.3333, rau:15.6667, dec:-48.0000, conname:"LUP"});
			arrIdentCon.push({ral: 0.0000, rau: 2.3333, dec:-48.1667, conname:"PHE"});
			arrIdentCon.push({ral: 2.6667, rau: 3.0000, dec:-49.0000, conname:"ERI"});
			arrIdentCon.push({ral: 4.0833, rau: 4.2667, dec:-49.0000, conname:"HOR"});
			arrIdentCon.push({ral: 4.2667, rau: 4.5000, dec:-49.0000, conname:"CAE"});
			arrIdentCon.push({ral:21.3333, rau:22.0000, dec:-50.0000, conname:"GRU"});
			arrIdentCon.push({ral: 6.0000, rau: 8.0000, dec:-50.7500, conname:"PUP"});
			arrIdentCon.push({ral: 8.0000, rau: 8.1667, dec:-50.7500, conname:"VEL"});
			arrIdentCon.push({ral: 2.4167, rau: 2.6667, dec:-51.0000, conname:"ERI"});
			arrIdentCon.push({ral: 3.8333, rau: 4.0833, dec:-51.0000, conname:"HOR"});
			arrIdentCon.push({ral: 0.0000, rau: 1.8333, dec:-51.5000, conname:"PHE"});
			arrIdentCon.push({ral: 6.0000, rau: 6.1667, dec:-52.5000, conname:"CAR"});
			arrIdentCon.push({ral: 8.1667, rau: 8.4500, dec:-53.0000, conname:"VEL"});
			arrIdentCon.push({ral: 3.5000, rau: 3.8333, dec:-53.1667, conname:"HOR"});
			arrIdentCon.push({ral: 3.8333, rau: 4.0000, dec:-53.1667, conname:"DOR"});
			arrIdentCon.push({ral: 0.0000, rau: 1.5833, dec:-53.5000, conname:"PHE"});
			arrIdentCon.push({ral: 2.1667, rau: 2.4167, dec:-54.0000, conname:"ERI"});
			arrIdentCon.push({ral: 4.5000, rau: 5.0000, dec:-54.0000, conname:"PIC"});
			arrIdentCon.push({ral:15.0500, rau:15.3333, dec:-54.0000, conname:"LUP"});
			arrIdentCon.push({ral: 8.4500, rau: 8.8333, dec:-54.5000, conname:"VEL"});
			arrIdentCon.push({ral: 6.1667, rau: 6.5000, dec:-55.0000, conname:"CAR"});
			arrIdentCon.push({ral:11.8333, rau:12.8333, dec:-55.0000, conname:"CEN"});
			arrIdentCon.push({ral:14.1667, rau:15.0500, dec:-55.0000, conname:"LUP"});
			arrIdentCon.push({ral:15.0500, rau:15.3333, dec:-55.0000, conname:"NOR"});
			arrIdentCon.push({ral: 4.0000, rau: 4.3333, dec:-56.5000, conname:"DOR"});
			arrIdentCon.push({ral: 8.8333, rau:11.0000, dec:-56.5000, conname:"VEL"});
			arrIdentCon.push({ral:11.0000, rau:11.2500, dec:-56.5000, conname:"CEN"});
			arrIdentCon.push({ral:17.5000, rau:18.0000, dec:-57.0000, conname:"ARA"});
			arrIdentCon.push({ral:18.0000, rau:20.3333, dec:-57.0000, conname:"TEL"});
			arrIdentCon.push({ral:22.0000, rau:23.3333, dec:-57.0000, conname:"GRU"});
			arrIdentCon.push({ral: 3.2000, rau: 3.5000, dec:-57.5000, conname:"HOR"});
			arrIdentCon.push({ral: 5.0000, rau: 5.5000, dec:-57.5000, conname:"PIC"});
			arrIdentCon.push({ral: 6.5000, rau: 6.8333, dec:-58.0000, conname:"CAR"});
			arrIdentCon.push({ral: 0.0000, rau: 1.3333, dec:-58.5000, conname:"PHE"});
			arrIdentCon.push({ral: 1.3333, rau: 2.1667, dec:-58.5000, conname:"ERI"});
			arrIdentCon.push({ral:23.3333, rau:24.0000, dec:-58.5000, conname:"PHE"});
			arrIdentCon.push({ral: 4.3333, rau: 4.5833, dec:-59.0000, conname:"DOR"});
			arrIdentCon.push({ral:15.3333, rau:16.4208, dec:-60.0000, conname:"NOR"});
			arrIdentCon.push({ral:20.3333, rau:21.3333, dec:-60.0000, conname:"IND"});
			arrIdentCon.push({ral: 5.5000, rau: 6.0000, dec:-61.0000, conname:"PIC"});
			arrIdentCon.push({ral:15.1667, rau:15.3333, dec:-61.0000, conname:"CIR"});
			arrIdentCon.push({ral:16.4208, rau:16.5833, dec:-61.0000, conname:"ARA"});
			arrIdentCon.push({ral:14.9167, rau:15.1667, dec:-63.5833, conname:"CIR"});
			arrIdentCon.push({ral:16.5833, rau:16.7500, dec:-63.5833, conname:"ARA"});
			arrIdentCon.push({ral: 6.0000, rau: 6.8333, dec:-64.0000, conname:"PIC"});
			arrIdentCon.push({ral: 6.8333, rau: 9.0333, dec:-64.0000, conname:"CAR"});
			arrIdentCon.push({ral:11.2500, rau:11.8333, dec:-64.0000, conname:"CEN"});
			arrIdentCon.push({ral:11.8333, rau:12.8333, dec:-64.0000, conname:"CRU"});
			arrIdentCon.push({ral:12.8333, rau:14.5333, dec:-64.0000, conname:"CEN"});
			arrIdentCon.push({ral:13.5000, rau:13.6667, dec:-65.0000, conname:"CIR"});
			arrIdentCon.push({ral:16.7500, rau:16.8333, dec:-65.0000, conname:"ARA"});
			arrIdentCon.push({ral: 2.1667, rau: 3.2000, dec:-67.5000, conname:"HOR"});
			arrIdentCon.push({ral: 3.2000, rau: 4.5833, dec:-67.5000, conname:"RET"});
			arrIdentCon.push({ral:14.7500, rau:14.9167, dec:-67.5000, conname:"CIR"});
			arrIdentCon.push({ral:16.8333, rau:17.5000, dec:-67.5000, conname:"ARA"});
			arrIdentCon.push({ral:17.5000, rau:18.0000, dec:-67.5000, conname:"PAV"});
			arrIdentCon.push({ral:22.0000, rau:23.3333, dec:-67.5000, conname:"TUC"});
			arrIdentCon.push({ral: 4.5833, rau: 6.5833, dec:-70.0000, conname:"DOR"});
			arrIdentCon.push({ral:13.6667, rau:14.7500, dec:-70.0000, conname:"CIR"});
			arrIdentCon.push({ral:14.7500, rau:17.0000, dec:-70.0000, conname:"TRA"});
			arrIdentCon.push({ral: 0.0000, rau: 1.3333, dec:-75.0000, conname:"TUC"});
			arrIdentCon.push({ral: 3.5000, rau: 4.5833, dec:-75.0000, conname:"HYI"});
			arrIdentCon.push({ral: 6.5833, rau: 9.0333, dec:-75.0000, conname:"VOL"});
			arrIdentCon.push({ral: 9.0333, rau:11.2500, dec:-75.0000, conname:"CAR"});
			arrIdentCon.push({ral:11.2500, rau:13.6667, dec:-75.0000, conname:"MUS"});
			arrIdentCon.push({ral:18.0000, rau:21.3333, dec:-75.0000, conname:"PAV"});
			arrIdentCon.push({ral:21.3333, rau:23.3333, dec:-75.0000, conname:"IND"});
			arrIdentCon.push({ral:23.3333, rau:24.0000, dec:-75.0000, conname:"TUC"});
			arrIdentCon.push({ral: 0.7500, rau: 1.3333, dec:-76.0000, conname:"TUC"});
			arrIdentCon.push({ral: 0.0000, rau: 3.5000, dec:-82.5000, conname:"HYI"});
			arrIdentCon.push({ral: 7.6667, rau:13.6667, dec:-82.5000, conname:"CHA"});
			arrIdentCon.push({ral:13.6667, rau:18.0000, dec:-82.5000, conname:"APS"});
			arrIdentCon.push({ral: 3.5000, rau: 7.6667, dec:-85.0000, conname:"MEN"});
			arrIdentCon.push({ral: 0.0000, rau:24.0000, dec:-90.0000, conname:"OCT"});			
				
		}

		private var EP1:Number = 0;
		private var EP2:Number = 0;
		private var x1:Array = new Array(3);
		private var x2:Array = new Array(3);
		private var r:Array = null;	

		/**
		 * Epoch1때에 적경,적위값을 Epoch2때의 적경 적위값으로 반환
		 * @param raHour 적경 (단위 Hour)
		 * @param decDeg 적위 (단위 degree)
		 * @param epoch1 위 적경,적위의 원기
		 * @parma epoch2 기준 원기 (기본값 1875년)
		 * @return x값은 적경(단위 Hour), y값은 적위(단위 degree )
		 * @see http://cdsarc.u-strasbg.fr/viz-bin/Cat?VI/42
		 * @see http://astrocomplutense.es/dobles/program.c
		 * 
		 */ 
		private function applyHergetPrecession(raHour:Number, decDeg:Number, epoch1:Number, epoch2:Number=1875):Point
		{
			var i:int;
			var j:int;
			var CDR:Number = 0.17453292519943e-01;
			var T:Number;
			var ST:Number;
			var A:Number;
			var B:Number;
			var C:Number;
			var CSR:Number;
			var SINA:Number;
			var SINB:Number;
			var SINC:Number;
			var COSA:Number;
			var COSB:Number;
			var COSC:Number;			
			var RArad:Number = raHour * ALConst.H2R;
			var DErad:Number = decDeg * ALConst.D2R;
			
			if( r == null )
			{
				r = new Array(3);
				r[0] = new Array(3);
				r[1] = new Array(3);
				r[2] = new Array(3);
			}
						
			A = Math.cos(DErad);
			x1[0] = A * Math.cos(RArad);
			x1[1] = A * Math.sin(RArad);
			x1[2] = Math.sin(DErad);
			if(EP1 == epoch1 && EP2 == epoch2);
			else
			{
				EP1 = epoch1;
				EP2 = epoch2;
				CSR = CDR/3600.0;
				T = 0.001*(EP2-EP1);
				ST = 0.001*(EP1-1900.0);
				A=CSR*T*(23042.53+ST*(139.75+0.06*ST)+T*(30.23-0.27*ST+18.0*T)); //zeta
				B=CSR*T*T*(79.27+0.66*ST+0.32*T)+A; //z
				C=CSR*T*(20046.85-ST*(85.33+0.37*ST)+T*(-42.67-0.37*ST-41.8*T)); //theta
				SINA = Math.sin(A);
				SINB = Math.sin(B);
				SINC = Math.sin(C);
				COSA = Math.cos(A);
				COSB = Math.cos(B);
				COSC = Math.cos(C);
				r[0][0]=COSA*COSB*COSC-SINA*SINB ;
				r[0][1]=-COSA*SINB-SINA*COSB*COSC ;
				r[0][2]=-COSB*SINC ;
				r[1][0]=SINA*COSB+COSA*SINB*COSC ;
				r[1][1]=COSA*COSB-SINA*SINB*COSC ;
				r[1][2]=-SINB*SINC ;
				r[2][0]=COSA*SINC ;
				r[2][1]=-SINA*SINC ;
				r[2][2]=COSC ;
			}
			
			for( i=0; i<3; i++)
			{
				x2[i] = 0.0;
				for( j=0; j<3; j++)
					x2[i] += r[i][j] * x1[j];
			}
			
			RArad = Math.atan2( x2[1], x2[0] );
			if(RArad<0) RArad = 6.28318530717948 + RArad ;
			DErad = Math.asin( x2[2] );
				
			return new Point( RArad * ALConst.R2H, DErad * ALConst.R2D );
		}

	}
}

class SingletonLock 
{
	
}